<template>
    <div class="box">
        <div><span>姓名:{{ data.username }}</span></div>
        <div><span>邮箱:{{ data.email }}</span></div>
        <div><span>创建日期:{{ data.date_joined }}</span></div>
        <div><span>学号:</span></div>
        <div><span>状态:</span></div>
        <div><span>学校:</span></div>
        <div><span>学院:</span></div>
        <div><span>年级:</span></div>
        <div><span>班级:</span></div>
        <div><span>姓名:</span></div>
        <div>

            <h2>权限&nbsp;&nbsp;<span style="color: #780000;">超级管理员</span></h2>
        </div>
    </div>
</template>

<script>
import { getUser } from "../api/userApi";
export default {
    data() {
        return {
            data:[]
        }
    },
    created() {
        this.getUserInfo();
    },
    methods: {
        getUserInfo() {
            getUser(0).then(response => {
                console.log(response, 1);
                this.data =  response
            }).catch(error => {
                console.log(error);
            });
        }
    }

}
</script>

<style scoped lang="less">
.box{
    display: inline-block;
    width: 100%;
    padding: 10px;
    // background-color: #dadada;
}
</style>
